package com.ysd.lis.entity.bac;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ysd.lis.entity.BaseEntity;
import com.ysd.lis.entity.BaseEntityJpa;
import com.ysd.lis.util.compare.Compare;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;
import java.math.BigDecimal;
import java.sql.Timestamp;

/**
 * <p>
 * 染色结果
 * </p>
 *
 * @author cfz
 * @since 2024-03-27
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Entity
@Table(name = "BAC_STAINING_RESULT")
@TableName(value = "BAC_STAINING_RESULT", autoResultMap = true)
public class BacStainingResult extends BaseEntityJpa {

    private static final long serialVersionUID = 1L;

    /**
     * 检验日期
     */
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    @TableField(value = "SAMPLEDA")
    @Column(name = "SAMPLEDA")
    private Timestamp sampleda;

    /**
     * 报告单元
     */
    @TableField("RPT_GROUP")
    @Column(name = "RPT_GROUP")
    private String rptGroup;

    /**
     * 标本号
     */
    @TableField("SAMPLE_NO")
    @Column(name = "SAMPLE_NO")
    private String sampleNo;

    /**
     * 检验主键
     */
    /*@TableField("MAININFO_ID")
    private String maininfoId;*/

    /**
     * 工作流程主键
     */
    /*@TableField("WK_FLW_ID")
    private String wkFlwId;*/

    /**
     * 工作流程节点主键
     */
    /*@TableField("WK_FLW_NODE_ID")
    private String wkFlwNodeId;*/

    /**
     * 细菌分离编号
     */
    @TableField("ISOLATE_NUM")
    @Column(name = "ISOLATE_NUM")
    private String isolateNum;

    /**
     * 染色方法编号
     */
    @TableField("STA_METHOD_NO")
    @Column(name = "STA_METHOD_NO")
    private String stainingMethNo;

    /**
     * 染色结论编号
     */
    /*@TableField("STA_CONCLUSION_NO")
    private String stainingConcNo;*/

    /**
     * 染色结论可选项编号
     */
    @TableField("STA_OPT_NO")
    @Column(name = "STA_OPT_NO")
    private String stainingConcOptNo;

    /**
     * 染色结论可选项名称
     */
    @TableField("STA_OPT_NA")
    @Column(name = "STA_OPT_NA")
    private String stainingConcOptNa;

    /**
     * 注解文本
     */
    @TableField("DESC_TEXT")
    @Column(name = "DESC_TEXT")
    private String descText;

    // /**
    //  * 操作日期
    //  */
    // @TableField("OPERATE_DATE")
    // private LocalDateTime operateDate;
    //
    // /**
    //  * 操作人编号
    //  */
    // @TableField("OPERATE_USER_NO")
    // private String operateUserNo;

    /**
     * 备注1
     */
    @TableField("REMARK1")
    @Column(name = "REMARK1")
    private String remark1;

    /**
     * 备注2
     */
    @TableField("REMARK2")
    @Column(name = "REMARK2")
    private String remark2;

    /**
     * 备注3
     */
    @TableField("REMARK3")
    @Column(name = "REMARK3")
    private String remark3;

    /**
     * 备注4
     */
    @TableField("REMARK4")
    @Column(name = "REMARK4")
    private String remark4;

    /**
     * 菌株ID
     */
    /*@TableField("STRAIN_ID")
    private String strainId;*/

    /**
     * 菌株名称
     */
    @TableField("STRAIN_NA")
    @Column(name = "STRAIN_NA")
    private String strainName;

    /**
     * 染色方法名称
     */
    @TableField("STA_METHOD_NA")
    @Column(name = "STA_METHOD_NA")
    private String stainingMethNa;

    /**
     * 染色结论名称
     */
    @TableField("STA_CONCLUSION_NA")
    @Column(name = "STA_CONCLUSION_NA")
    private String stainingConcNa;

    /**
     * 处理类型
     */
    @TableField("HANDLE_TYPE")
    @Column(name = "HANDLE_TYPE")
    private String handleType;


    /**
     * 是否默认结果
     */
    @TableField("IS_DEFAULT")
    @Column(name = "IS_DEFAULT")
    private Integer isDefault;

    /**
     * 培养基主键
     */
    /*@TableField("CULTURE_MEDIUM_ID")
    private String cultureMediumId;*/

    /**
     * 染色方法主键
     */
    /*@TableField("STAINING_METHOD_ID")
    private String stainingMethodId;*/

    /**
     * 染色结论主键
     */
    /*@TableField("STAINING_CONCLUSION_ID")
    private String stainingConclusionId;*/

    /**
     * 染色结果主键
     */
    /*@TableField("STAINING_OPTIONS_ID")
    private String stainingOptionsId;*/

    /**
     * 培养基组合ID
     */
    /*@TableField("COMBINATION_ID")
    private String combinationId;*/

    @TableField(exist = false)
    @Transient
    private String userName;

    /**
     * 检验方案编号
     */
    @TableField("TEST_FLOW_NO")
    @Column(name = "TEST_FLOW_NO")
    private String testFlowNo;
    /**
     * 检验方案节点编号
     */
    @TableField("TEST_NODE_NO")
    @Column(name = "TEST_NODE_NO")
    private String testNodeNo;
    /**
     * 菌株编号
     */
    @TableField("STRAIN_NO")
    @Column(name = "STRAIN_NO")
    private String strainNo;


    /**
     * 培养基编号
     */
    @TableField("CUL_MEDIUM_NO")
    @Column(name = "CUL_MEDIUM_NO")
    private String culMediumNo;

    /**
     * 培养基名称
     */
    @TableField(exist = false)
    @Transient
    private String culMediumNa;
    /**
     * 染色结论编号
     */
    @TableField("STA_CONCLUSION_NO")
    @Column(name = "STA_CONCLUSION_NO")
    private String staConclusionNo;
    /**
     * 培养基组合编号
     */
    @TableField("CUL_COMBINA_NO")
    @Column(name = "CUL_COMBINA_NO")
    private String culCombinaNo;

    @TableField("PARENT_ID")
    @Column(name = "PARENT_ID")
    private String parentId;

    @TableField("IS_ALARM")
    @Column(name = "IS_ALARM")
    private Integer isAlarm;

    /**
     * 是否发布二级报告
     */
    @TableField("IS_PUSH_SEC_REPORT")
    @Column(name = "IS_PUSH_SEC_REPORT")
    private Integer isPushSecReport;

    /**
     * 病历号
     */
    @TableField(exist = false)
    @Transient
    private String patNo;

    /**
     * 检验目的
     */
    @TableField(exist = false)
    @Transient
    private String testPurpose;

    /**
     * 检验目的
     */
    @TableField(exist = false)
    @Transient
    private String reqPurpose;



    /**
     * 标本类型
     */
    @TableField(exist = false)
    @Transient
    private String traits;

    /**
     * 标本类型
     */
    @TableField(exist = false)
    @Transient
    private String sampleType;

    /**
     * 审核医生编号
     */
    @TableField(exist = false)
    @Transient
    private String chkDoctor;

    /**
     * 审核时间
     */
    @TableField(exist = false)
    @Transient
    private Timestamp chkTime;

    /**
     * 是否审核    如：0未审核、1初审、2审核，保存的是0，1，2 stateNa
     */
    @TableField(exist = false)
    @Transient
    private BigDecimal isChk;

}
